package com.cmwa.solution.sys.msg.dao;

import org.apache.ibatis.annotations.Param;

import com.cmwa.solution.annotation.MybatisDao;
import com.cmwa.solution.base.dao.BaseDao;
import com.cmwa.solution.sys.msg.vo.MsgSendVo;

@MybatisDao // 注解为mybatis的业务接口
public interface IMsgSendDao extends BaseDao<MsgSendVo>{

	public String getMaxSendDate(@Param("title") String title);
	
	/**
	 * 查询X分钟类某个邮件类型的数量
	 * @param subType
	 * @param minute
	 * @return
	 */
	int getEmailTypeCount(@Param("msgCode")String msgCode, @Param("minute")Integer minute);

	/**
	 * 查询X分钟类收件人相同的邮件数量
	 * @param recipientsStr
	 * @param minute
	 */
	int getEmailRecipientCount(@Param("recipients")String recipients, @Param("minute")Integer minute);

	/**
	 * 查询X分钟类标题和收件人相同的数量
	 * @param recipientsStr
	 * @param minute
	 * @return
	 */
	public int getEmailTitleAndRecipientCount(@Param("title")String title, @Param("recipients")String recipientsStr, @Param("minute")Integer minute);
}
